package com.chanyachting.emall.service;

import java.util.List;

import com.chanyachting.emall.domain.Newsactivity;
import com.chanyachting.emall.domain.Periodical;

public interface NewsActivityService {
	
	
	
	public boolean createNewsActivity(Newsactivity na);
	
	
	public boolean updateNewsActivity(Newsactivity na);
	
	
	public boolean deleteNewsActivity(Newsactivity na);
	
	
	public Newsactivity getOneNewsActivity(Integer id);
	
	
	public List<Newsactivity> getAllNewsActivity();
	
	
	public List<Newsactivity> getMemberNewsActivity(Integer memberId);
	
	//获得会员已经发布的新闻活动列表
	public List<Newsactivity> getMemberReleasedNewsActivity(Integer memberId);
	
	//获得会员还没有发布的新闻活动列表
	public List<Newsactivity> getMemberNotReleasedNewsActivity(Integer memberId);
	
	
	//刷新
	public void refresh(Newsactivity na);
	
	//上架
	public void release(Newsactivity na);
	
	//下架
	public void delrelease(Newsactivity na);
	
	public List<Newsactivity> getNewsActivityByChannelId(Integer channelId,int pageNo,int pageSize);
	
	public List<Newsactivity> getNewsActivityBySubChannelId(Integer subChannelId,int pageNo,int pageSize);

	public List<Newsactivity> getNewsActivityByNewsid(Integer newsid);
	
	public int getAllNewsactivityById(String type,String id);
	
	public Newsactivity getOneNewsactivityById(String memberId,String id);
	
	public List<Newsactivity> getNewsBySubChannalId(String subChannalId,int currentPage,int pageSize,boolean isRecommend);
	
	public int getNewsCountBySubChannalId(String subChannalId,boolean isRecommend);
	
	public List<Newsactivity> getNewsByChannalId(String channalId,int currentPage,int pageSize,boolean isRecommend);
	
	public int getNewsCountByChannalId(String channalId,boolean isRecommend);
	
	public List<Newsactivity> getNewsByKeywords1(Newsactivity news,int currentPage,int pageSize,Periodical pd,boolean isRecommend);
	
	public List<Newsactivity> getNewsByKeywords2(Newsactivity news,int currentPage,int pageSize,Periodical pd,boolean isRecommend);
	
	public int getNewsCountByKeywords1(Newsactivity news,Periodical pd,boolean isRecommend);
	
	public int getNewsCountByKeywords2(Newsactivity news,Periodical pd,boolean isRecommend);
	
	public Newsactivity getOneNewsById(String id);
}
